/**
 * Created by ljx on 2020/6/12.
 */

const state = {
  isOpenSlide: 'Y', // 是否显示侧边栏Y为展示，N为不展示
  isOpenTop: 'Y' // 是否显示顶部栏Y为展示，N为不展示
}

const mutations = {
  SET_ISOPENSLIDE(state, flag) {
    state.isOpenSlide = flag
  },
  SET_ISOPENTOP(state, flag) {
    state.isOpenTop = flag
  }
}

const actions = {
  setIsOpenSlide({ commit }, flag) {
    commit('SET_ISOPENSLIDE', flag)
  },
  setIsOpenTop({ commit }, flag) {
    commit('SET_ISOPENTOP', flag)
  }
}

export default {
  namespaced: true,
  state,
  mutations,
  actions
}
